home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / cpp_libs / answrbok / 7_10.lha / 7_10 / qh_tail.c < prev    next >
Text File  |  1993-08-08  |  644b  |  24 lines

  1. * Copyright (c) 1990 by AT&T Bell Telephone Laboratories, Incorporated. */
  2. * The C++ Answer Book */
  3. * Tony Hansen */
  4. * All rights reserved. */
  5. include <process.h>
  6. include <debug.h>    /* DELETE */
  7. / Return the queue_tail associated with this queue.
  8. / If it doesn't already exist, create it.
  9. ueue_tail *queue_head::tail()
  10.  
  11.    if (debug) /*DELETE*/ cerr << "queue_head" << this << "::tail()\n";
  12.    process_queue *q = qh_queue;
  13.    register queue_tail *t = q->q_tail;
  14.  
  15.    if (!t)
  16. {
  17. q->q_tail = t = new queue_tail(qh_mode, 0);
  18. t->qt_queue = q;
  19. }
  20.  
  21.    if (debug) /*DELETE*/ cerr << "<<<< queue_head" << this << "::tail() <- " << t << "\n";
  22.    return t;
  23.  
  24.